nice_things/io/cat.sh
cat
Since 0.3.0 · Source
import "{ cat }" from nice_things/io/cat.sh
Synopsiscat [-u] [--] [<file>…]
Configuration
–
Description
Concatenate <file>(s) to stdout. With no <file>, or when <file> is -, read stdin.
This function is a simple POSIX-compatible cat utility in pure shell script.
Note
This function only exists to provide a pure sh implementation.
catis a very basic core utility and is always likely to be available and will be much faster than this function. You should prefer the platform'scatcommand over this function in most cases.
Options
-u: Ignored.--: End of options.
Operands<file>: Optional file to read, or - to read stdin.
Stdin
Stdin will be read when no <file> parameter is specified, or when <file> is -.
Stdout
Will echo all files' contents to stdout.
Stderr
–
Exit status0: Successful completion.
Abort
–
Usage examples
cat /path/to/file